import Vue from 'vue';
import Vuex from 'vuex';

Vue.use(Vuex);

export default new Vuex.Store({
  state: {
    city: '',
    searchState: false
  },
  mutations: {
    changeCity: function (state, cityName) {
      state.city = cityName
      localStorage.city = cityName
    },
    changeSearch: function (state, searchState) {
      state.searchState = searchState
    }
  },
  actions: {},
  modules: {},
});
